const RoleCtrl = require("./role.ctrl");
const checkUserInfo = require("../../middleware/checkUserInfo");
const { checkPermission } = require("../../config/acl");
module.exports = (router) => {
	router.get("/roles", checkUserInfo, checkPermission("list_role"), RoleCtrl.list);
	router.post("/roles", checkUserInfo, checkPermission("create_role"), RoleCtrl.create);
	router.put("/roles", checkUserInfo, checkPermission("create_role"), RoleCtrl.update);
	router.delete("/roles/:ids", checkUserInfo, checkPermission("delete_role"), RoleCtrl.del);
};